<input name="{$idStr}" id="{$idStr}" value="{$selectStr}" ts-selected="{$selectId}" <if condition="$isV eq 1">lay-verify="required"</if> placeholder="请选择{$msg}" autocomplete="off" class="layui-input" type="text">
<script>
layui.config({
	base: '__ADMIN__'
}).extend({
	tableSelect: '/lib/extend/tableSelect',
}).use(['tableSelect'],function(){
	var tableSelect = layui.tableSelect,
		$ = layui.$;
	
	//数据多选
	tableSelect.render({
		elem: '#{$idStr}',
		searchKey: '{$show_name}',
		checkedKey: 'id',
		searchPlaceholder: '请输入搜索关键词',
		table: {
			url: mUrl+'{$tableUrl}'
			,method: 'post'
			,cols: [{$cols}]
			,cellMinWidth : 100
			,page : true
			,page:  {
				 // 限定条数   总数、计数  上一页     页     下一页    到第几页、跳
		         layout: ['refresh','prev', 'page', 'next', 'skip','count','limit']
	             ,curr: 1 
	             ,groups: 10
	             ,first: '首页'
	             ,last: '尾页' 
	         }
			,limit : {$limit}
			,limits : [20,30,40,50,60,70,80,90,100,150,200]
			,even: true //开启隔行背景
			,loading: true
		},
		done: function (elem, data) {
			var NEWJSON = [],IDJSON = [];
			layui.each(data.data, function (index, item) {
				NEWJSON.push(item.{$show_name});
				IDJSON.push(item.{$show_value});
			});
			//elem.val(NEWJSON.join(","));
			elem.attr("value",NEWJSON.join(","));
			elem.attr("ts-selected",IDJSON.join(","));
		}
	});
	
});

</script>